home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / idl / nsrootidl.idl < prev    next >
Text File  |  2006-05-08  |  5KB  |  129 lines

  1. /* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
  2. /* ***** BEGIN LICENSE BLOCK *****
  3.  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
  4.  *
  5.  * The contents of this file are subject to the Mozilla Public License Version
  6.  * 1.1 (the "License"); you may not use this file except in compliance with
  7.  * the License. You may obtain a copy of the License at
  8.  * http://www.mozilla.org/MPL/
  9.  *
  10.  * Software distributed under the License is distributed on an "AS IS" basis,
  11.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  12.  * for the specific language governing rights and limitations under the
  13.  * License.
  14.  *
  15.  * The Original Code is mozilla.org code.
  16.  *
  17.  * The Initial Developer of the Original Code is
  18.  * Netscape Communications Corporation.
  19.  * Portions created by the Initial Developer are Copyright (C) 1998
  20.  * the Initial Developer. All Rights Reserved.
  21.  *
  22.  * Contributor(s):
  23.  *   Dan Rosen <dr@netscape.com>
  24.  *
  25.  * Alternatively, the contents of this file may be used under the terms of
  26.  * either of the GNU General Public License Version 2 or later (the "GPL"),
  27.  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
  28.  * in which case the provisions of the GPL or the LGPL are applicable instead
  29.  * of those above. If you wish to allow use of your version of this file only
  30.  * under the terms of either the GPL or the LGPL, and not to allow others to
  31.  * use your version of this file under the terms of the MPL, indicate your
  32.  * decision by deleting the provisions above and replace them with the notice
  33.  * and other provisions required by the GPL or the LGPL. If you do not delete
  34.  * the provisions above, a recipient may use your version of this file under
  35.  * the terms of any one of the MPL, the GPL or the LGPL.
  36.  *
  37.  * ***** END LICENSE BLOCK ***** */
  38.  
  39. /**
  40.  * Root idl declarations to be used by all.
  41.  * @status FROZEN
  42.  */
  43.  
  44. %{C++
  45.  
  46. #include "nscore.h"
  47. #include "prtime.h"
  48.  
  49. /*
  50.  * Forward declarations for new string types
  51.  */
  52. class nsAString;
  53. class nsACString;
  54.  
  55. /* 
  56.  * Start commenting out the C++ versions of the below in the output header
  57.  */
  58. #if 0
  59. %}
  60.  
  61. typedef boolean             PRBool   ;
  62. typedef octet               PRUint8  ;
  63. typedef unsigned short      PRUint16 ;
  64. typedef unsigned short      PRUnichar;
  65. typedef unsigned long       PRUint32 ;
  66. typedef unsigned long long  PRUint64 ;
  67. typedef unsigned long long  PRTime   ;
  68. typedef short               PRInt16  ;
  69. typedef long                PRInt32  ;
  70. typedef long long           PRInt64  ;
  71.  
  72. typedef unsigned long       nsrefcnt ;
  73. typedef unsigned long       nsresult ;
  74.  
  75. // XXX need this built into xpidl compiler so that it's really size_t or PRSize
  76. // and it's scriptable:
  77. typedef unsigned long       size_t;
  78.  
  79. [ptr]         native voidPtr(void);
  80. [ptr]         native charPtr(char);
  81. [ptr]         native unicharPtr(PRUnichar);
  82.  
  83. [ref, nsid]   native nsIDRef(nsID);
  84. [ref, nsid]   native nsIIDRef(nsIID);
  85. [ref, nsid]   native nsCIDRef(nsCID);
  86.  
  87. [ptr, nsid]   native nsIDPtr(nsID);
  88. [ptr, nsid]   native nsIIDPtr(nsIID);
  89. [ptr, nsid]   native nsCIDPtr(nsCID);
  90.  
  91. // NOTE: Be careful in using the following 3 types. The *Ref and *Ptr variants 
  92. // are more commonly used (and better supported). Those variants require 
  93. // nsMemory alloc'd copies when used as 'out' params while these types do not. 
  94. // However, currently these types can not be used for 'in' params. And, methods 
  95. // that use them as 'out' params *must* be declared [notxpcom] (with an explicit 
  96. // return type of nsresult). This makes such methods implicitly not scriptable.
  97. // Use of these types in methods without a [notxpcom] declaration will cause
  98. // the xpidl compiler to raise an error.
  99. // See: http://bugzilla.mozilla.org/show_bug.cgi?id=93792
  100.  
  101. [nsid]        native nsIID(nsIID);
  102. [nsid]        native nsID(nsID);
  103. [nsid]        native nsCID(nsCID);
  104.  
  105. [ptr]         native nsQIResult(void);
  106.  
  107. [ref, domstring] native DOMString(ignored);
  108. [ref, domstring] native DOMStringRef(ignored);
  109. [ptr, domstring] native DOMStringPtr(ignored);
  110.  
  111. [ref, utf8string] native AUTF8String(ignored);
  112. [ref, utf8string] native AUTF8StringRef(ignored);
  113. [ptr, utf8string] native AUTF8StringPtr(ignored);
  114.  
  115. [ref, cstring] native ACString(ignored);
  116. [ref, cstring] native ACStringRef(ignored);
  117. [ptr, cstring] native ACStringPtr(ignored);
  118.  
  119. [ref, astring] native AString(ignored);
  120. [ref, astring] native AStringRef(ignored);
  121. [ptr, astring] native AStringPtr(ignored);
  122.  
  123. %{C++
  124. /* 
  125.  * End commenting out the C++ versions of the above in the output header
  126.  */
  127. #endif
  128. %}
  129.